<div class="breadcrumb">
        <a href="/admin/index">Home</a>
         :: <a href="/admin/listgroupuser">User Group</a>
</div>
    <?php  if(isset($this->success)) {?>
<div class="success" style="text-align: center;"><?php echo $this->success;?></div>
	<?php }?>
	<?php if(isset($this->warning)) {?>
<div class="warning" style="text-align: center;"><?php  echo $this->warning;?></div>
	<?php }?>
<div class="box">
    <div class="heading">
      <h1><img alt="" src="/images/admin/user-group.png"> User Group</h1>
      <div class="buttons">
		<a class="button" onclick="location = '/admin/listgroupuser/insert'">Insert</a>
		<a class="button" onclick="$('form').submit();">Delete</a>
	  </div>
    </div>
    <div class="content">
      <form id="form" enctype="multipart/form-data" method="post" action="/admin/listgroupuser/delete">
        <table class="list">
          <thead>
            <tr>
              <td width="1" style="text-align: center;"><input type="checkbox" onclick="$('input[name*=\'selected\']').attr('checked', this.checked);"></td>
              <td class="left">User Group Name
                </td>
              <td class="right">Action</td>
            </tr>
          </thead>
          <tbody>
            <?php if(isset($this->data_user)) {?>
               <?php foreach($this->data_user as $data) {?>
            <tr>
              <td style="text-align: center;">
              	<input type="checkbox" value="<?php echo $data['group_id'];?>" name="selected[]">
              </td>
              <td class="left"><?php echo $data['group_name'];?></td>
              <td class="right">
              	[ <a href="/admin/listgroupuser/insert?user_group_id=<?php echo $data['group_id'];?>">Edit</a> ]
              </td>
            </tr>
           <?php } }?>
        </tbody>
        </table>
      </form>
    </div>
</div>
